package com.jiuyou.clientController.config;

import com.jiuyou.clientController.base.ClientBaseController;
import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.system.service.ISysConfigService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletRequest;

/**
 * majie
 */
@RestController
@RequestMapping("/client/config")
public class ConfigClientController extends ClientBaseController {
    @Autowired
    private ISysConfigService configService;

    /**
     * 根据key获取参数设置中配置的值
     * @param key
     * @return
     */
    @PostMapping("/getConfigByKey/{key}")
    public String getConfigByKey(@PathVariable String key, HttpServletRequest request){

       return configService.selectConfigByKey(key);
    }
}
